package com.platform.framework.controller;

import java.io.IOException;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.platform.framework.entity.User;
import com.platform.framework.serviceinf.UserService;

/**
 * ����Controller��
 * @author Administrator
 *
 */
@Controller
@RequestMapping("/user")
public class UserController {

	@Resource
	private UserService userService;
	
	@RequestMapping("/getByUserName")
	public void getByUserName(User user,HttpServletRequest request,HttpServletResponse resp) throws IOException{
		User byUserName = userService.getByUserName(user.getUsername());
		resp.getWriter().write(byUserName.getCreator());
	}
}
